package com.hnkywl.sts.entity.cwgl.kmys;

import com.hnkywl.sts.entity.BaseEntity;
import com.hnkywl.sts.entity.base.Sjzdz;
import com.hnkywl.sts.entity.organ.Nbgs;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

import javax.persistence.*;

/**
 * Created with IntelliJ IDEA.
 * User: ccr
 * Date: 13-5-16
 * Time: 下午9:25
 * To change this template use File | Settings | File Templates.
 */
@Entity
@Table(name = "T_SYS_CYFYYS")
public class Cyfyys extends BaseEntity {
    @Id
    @SequenceGenerator(name = "seqCyfyys", allocationSize = 1, sequenceName = "SEQ_SYS_CYFYYS")
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "seqCyfyys")
    private Long id;
    /**
     * 作为查找的唯一表示，固定不变
     */
    private String codeId;

    /**
     * 费用科目全称
     */
    private String fykmqc;

    /**
     * 费用科目简称
     */
    private String fykmjc;

    /**
     * 科目
     */
    private String kmdm;
    /**
     * 费用类别 1.经营费用 jyfy 2.管理费用 glfy 3.财务费用 cwfy
     */
    private String fylb;

    /**
     * 税率
     */
    private Double sl;

    /**
     * 系统分类   1.运费  yf 2.吊费  df 3 加班费 jbf
     */
    private String xtfl;

    /**
     * 关联常用科目代码映射
     */
    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "CYKMDMYS_ID")
    private Cykmdmys cykmdmys;

    /**
     * 公司
     */
    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "NBGS_ID")
    @NotFound(action = NotFoundAction.IGNORE)
    private Nbgs nbgs;

    /**
     * 排序号码
     */
    private Integer pxh;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getCodeId() {
        return codeId;
    }

    public void setCodeId(String codeId) {
        this.codeId = codeId;
    }

    public String getFykmqc() {
        return fykmqc;
    }

    public void setFykmqc(String fykmqc) {
        this.fykmqc = fykmqc;
    }

    public String getFykmjc() {
        return fykmjc;
    }

    public void setFykmjc(String fykmjc) {
        this.fykmjc = fykmjc;
    }

    public String getKmdm() {
        return kmdm;
    }

    public void setKmdm(String kmdm) {
        this.kmdm = kmdm;
    }

    public String getFylb() {
        return fylb;
    }

    public void setFylb(String fylb) {
        this.fylb = fylb;
    }

    public Double getSl() {
        return sl;
    }

    public void setSl(Double sl) {
        this.sl = sl;
    }

    public String getXtfl() {
        return xtfl;
    }

    public void setXtfl(String xtfl) {
        this.xtfl = xtfl;
    }

    public Cykmdmys getCykmdmys() {
        return cykmdmys;
    }

    public void setCykmdmys(Cykmdmys cykmdmys) {
        this.cykmdmys = cykmdmys;
    }

    public Nbgs getNbgs() {
        return nbgs;
    }

    public void setNbgs(Nbgs nbgs) {
        this.nbgs = nbgs;
    }

    public Integer getPxh() {
        return pxh;
    }

    public void setPxh(Integer pxh) {
        this.pxh = pxh;
    }
}
